$(document).ready(function() {

	//开场第一屏动画开始

	setTimeout(function() {

		$(".zss_yimeng .zss_title1").addClass("zss_ymscal");

		$(".zss_whzz").delay(300).animate({

			top: 0

		}, 1000, 'easeOutQuart')

	}, 300);

	//开场第一屏动画结束

	$(".dowebok").fullpage({

		slidesColor: ['#F4F4F6', 'white', '#FFFEF2', 'white', '#FFFEF2', 'red'],

		verticalCentered: true,

		anchors: ['page1', 'page2', 'page3', 'page4', 'page5', 'page6'],

		menu: '#zss_nav',

		//paddingTop: '3rem',

		scrollingSpeed: 600,

		easing: "easeOutCubic",

		navigation: true,

		css3: true,

		afterLoad: function(anchorLink, index) {

			if(index == '1') {

				$(".zss_yimeng .zss_title1").addClass("zss_ymscal");

				$(".zss_whzz1").delay(300).animate({

					top: '0'

				}, 1000, 'easeOutQuart')

			}

			if(index == 2) {

				$(".zss_hengline").addClass("helinadd")

				setTimeout(function() {
					$('.zss_twobox1').delay(200).animate({

						left: '0'

					}, 1400, 'easeOutExpo');

					$('.zss_twobox2').delay(200).animate({

						right: '0'

					}, 1400, 'easeOutExpo');
				}, 400)

			}

			if(index == 3) {

				$('.zss_se3box h3').animate({

					top: '0'

				}, 1000, 'easeOutExpo');

				$('.zss_se3box h5').delay(200).animate({

					top: '0'

				}, 1000, 'easeOutExpo');

				$('.zss_se3box img').css({
					"transform": "scale(1)",
					"-webkit-transform": "scale(1)",
					"-moz-transform": "scale(1)",
					"-ms-transform": "scale(1)"
				})

			}

			if(index == 4) {

				$('.sec4img1,.sec4img2,.sec4img3').delay(200).animate({

					right: '0'

				}, 2000, 'easeOutExpo');

				setTimeout(function() {
					$('.zss_sec4textbox h4').css({
						"left": "0",
						"transform": "scale(1)",
						"-webkit-transform": "scale(1)",
						"-moz-transform": "scale(1)",
						"-ms-transform": "scale(1)"
					})
				}, 1000);

				$('.zss_sec4textbox').find('p').fadeIn(2000);

			}

			if(index == 5) {

				$('.section5').find('p').fadeIn(2000);

				$('.zss_vrbox h3').animate({

					right: '0'

				}, 1200, 'easeOutQuart');

				setTimeout(function() {
					$('.zss_vrbox .img1').css({
						"transform": "scale(1) rotate(720deg)",
						"-webkit-transform": "scale(1) rotate(720deg)",
						"-moz-transform": "scale(1) rotate(720deg)",
						"-ms-transform": "scale(1) rotate(720deg)"
					})
				}, 800);

				setTimeout(function() {
					$('.zss_vrbox .img2').css({
						"transform": "scale(1) rotate(720deg)",
						"-webkit-transform": "scale(1) rotate(720deg)",
						"-moz-transform": "scale(1) rotate(720deg)",
						"-ms-transform": "scale(1) rotate(720deg)"
					})
				}, 1000);

				setTimeout(function() {
					$('.zss_vrbox .img3').css({
						"transform": "scale(1) rotate(720deg)",
						"-webkit-transform": "scale(1) rotate(720deg)",
						"-moz-transform": "scale(1) rotate(720deg)",
						"-ms-transform": "scale(1) rotate(720deg)"
					})
				}, 1200);

			}

			if(index == 6) {

				$(".zss_jybox").addClass("addzss_jybox");

				setTimeout(function() {
					$(".zss_jybox .p1,.zss_jybox .p3").animate({

						right: '0'

					}, 1000, 'easeOutQuart');
					$(".zss_jybox .p2").animate({

						left: '0'

					}, 1000, 'easeOutQuart');
				}, 800)

			}
		},

		onLeave: function(index, direction) {

			if(index == '1') {

				$(".zss_yimeng .zss_title1").removeClass("zss_ymscal");

				$(".zss_whzz1").delay(500).animate({

					top: '-100rem'

				}, 1000, 'easeOutQuart')

			}

			if(index == '2') {

				$(".zss_hengline").removeClass("helinadd")

				setTimeout(function() {
					$('.zss_twobox1').delay(200).animate({

						left: '-300%'

					}, 1, 'easeOutExpo');

					$('.zss_twobox2').delay(200).animate({

						right: '-300%'

					}, 1, 'easeOutExpo');
				}, 600)

			}

			if(index == '3') {

				$('.zss_se3box h3').delay(300).animate({

					top: '100rem'

				}, 1000, 'easeOutExpo');

				$('.zss_se3box h5').delay(600).animate({

					top: '100rem'

				}, 1000, 'easeOutExpo');

				setTimeout(function() {
					$('.zss_se3box img').css({
						"transform": "scale(0)",
						"-webkit-transform": "scale(0)",
						"-moz-transform": "scale(0)",
						"-ms-transform": "scale(0)"
					})
				}, 1500);

			}

			if(index == '4') {

				$('.sec4img1,.sec4img2,.sec4img3').delay(200).animate({

					right: '300rem'

				}, 500, 'easeOutExpo');

				setTimeout(function() {

					$('.zss_sec4textbox h4').css({
						"left": "20rem",
						"transform": "scale(0)",
						"-webkit-transform": "scale(0)",
						"-moz-transform": "scale(0)",
						"-ms-transform": "scale(0)"
					})

				}, 200);

				$('.zss_sec4textbox').find('p').fadeOut(2000);

			}

			if(index == '5') {

				$('.section5').find('p').fadeOut(2000);

				$('.zss_vrbox h3').animate({

					right: '120%'

				}, 1000, 'easeOutQuart');

				setTimeout(function() {
					$('.zss_vrbox .img1').css({
						"transform": "scale(0) rotate(0)",
						"-webkit-transform": "scale(0) rotate(0)",
						"-moz-transform": "scale(0) rotate(0)",
						"-ms-transform": "scale(0) rotate(0)"
					})
				}, 800);

				setTimeout(function() {
					$('.zss_vrbox .img2').css({
						"transform": "scale(0) rotate(0)",
						"-webkit-transform": "scale(0) rotate(0)",
						"-moz-transform": "scale(0) rotate(0)",
						"-ms-transform": "scale(0) rotate(0)"
					})
				}, 1000);

				setTimeout(function() {
					$('.zss_vrbox .img3').css({
						"transform": "scale(0) rotate(0)",
						"-webkit-transform": "scale(0) rotate(0)",
						"-moz-transform": "scale(0) rotate(0)",
						"-ms-transform": "scale(0) rotate(0)"
					})
				}, 1200);

			}

			if(index == '6') {

				$(".zss_jybox").removeClass("addzss_jybox");

				setTimeout(function() {
					$(".zss_jybox .p1,.zss_jybox .p3").animate({

						right: '100rem'

					}, 1, 'easeOutQuart');
					$(".zss_jybox .p2").animate({

						left: '100rem'

					}, 1, 'easeOutQuart');
				}, 1000)

			}
		}

	});

});